//before you use this hud you need to set up a few things below and add them to your config
//
//-----------FIRST BACKUP YOUR SETTINGS!------------------------------------------------------------------//
//
//to make sure you safe all your settings go ingame, bring up the console (ctrl+alt+~) and type in the following:
//								/writeconfig backup
//this should create a file called backup.cfg in your quakelive/home/baseq3/ folder that holds all your settings
//also make sure you copy your autoexec.cfg and any other configs you use
//
//--------------------------------------------------------------------------------------------------------//
//
//now copy everthing inside this (.../holmesHUD/complete version/) folder to quakelive/home/ and check to integrate into existing folders
//the UI folder contains a holmesHUD Folder containing a bunch of .menu files and .cfg files
//the .menu files are the HUD elements, the filename usually reveals their purpose
//the .cfg files are what you actually set ingame or via your cfg as your hudfile and contain compositions of different .menu elements
//you can of course change these or add your own composition of elements, but the scripts and binds below should provide you 
//with everything you need to access it all ingame.
//
//now on to what you actually need to set up for this to work:
//
//the weaponconfig section is needed for the custom weapon icons and ammo bars to work properly
//if you already use these cg_weaponconfig settings make sure to add the content below to your own settings 
//in your config. if you dont use these cvars but have set weaponsettings via the ingame menu, try searching
//for cg_weaponconfig in your backup.cfg that you have hopefully created by now. if the cg_weaponconfig variables
//in your backup.cfg hold anything at all just copy them into your config and add the settings in the weaponconfig
//section below.
//
//
//the rebinds section is important - the altbind script changes a couple of binds (mostly number keys 1-9) upon holding down a modifier key and
//uses these custom cvars to rebind the keys to their original bindings when the modifier is released or voting is finished or cancelled.
//make sure you set these up to restore your original bindings of these keys


//how to use these bindings and scripts:
//
//F9 -	Loads the main HUD (made mainly for duel, but works with all gametypes) - repeated keypresses toggle different sized health and armor bars
//F10 -	Loads the Clan Arena HUD (works only in Clan arena and Freeze Tag)
//F11 -	Loads the Instagib HUD (should work in all gametypes, only useful for instagib though)
//
//alt+F9,alt+F10,alt+F11 - same as above, only without the custom crosshairs
//
//alt+V -	brings up the voting menue - Voting is done via the number keys (1-9)
//alt+b -	changes the binds for the voting menue to match a gametype (cycles through duel-tdm-ca-ctf) [note: there is a little widget visible in warmup mode to let you know if your current binds match the current gametype, just press alt+b until the red dots line up]
//
//t -	toggles the timer between small and large version

//have some feedback, encountered a bug, suggestions? you can reach me at holmes_quakelive@web.de

//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
//----------------------ADD EVERYTHING BELOW THIS LINE TO YOUR CONFIG! (make sure to set up the binds first, though)----------------------------//
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

  //                      --------
 //                     / bindings /
//                      --------

	 bind ALT			"+altbind"					//this is the modifier key used to toggle voting, HUD's and bindings. while this key is held down the binds in the altbindings section are active
	 
	 
	 //---IF YOU CHANGE THESE 3 REMEMBER TO ADJUST THE REBIND AND ALTBIND cvar's!!!---//
	 bind F9            "vstr hud1"			//this toggles through the default (duel) hud with 4 different bar sizes
	 bind F10           "vstr hud2"			//this loads the clan arena hud
	 bind F11           "vstr hud3"			//this loads the instagib hud
	 //---IF YOU CHANGE THESE 3 REMEMBER TO ADJUST THE REBIND AND ALTBIND cvar's!!!---//
	 
	 
	 bind t				"vstr timertoggle"			//this key is used to toggle the timer between small and large verson
	 bind space         "+zoom;+zoom_crosshair"		//either rebind this key to your liking or add [;+zoom_crosshair] (without brackets) to your +zoom bind, if you dont want the zoom crosshair just dont add this line


	  
  //                      ------------
 //                     / altbindings /
//                      ------------

	 set altbind_v "bind v vstr voting_toggle"		//you can change these keys if you want to, if you do however, remember to change the rebind settings below (rebind_b and rebind_v)
	 set altbind_b "bind b vstr binds_toggle"		//example: set_altbind_v "bind [your_key] vstr voting_toggle"
	 
	 
	 set altbind_f9            "vstr hud1"			//this toggles through the default (duel) hud with 4 different bar sizes without crosshairs
	 set altbind_f10           "vstr hud2"			//this loads the clan arena hud without crosshairs
	 set altbind_f11           "vstr hud3"			//this loads the instagib hud without crosshairs


  //                     -------
 //                   / rebinds /
//                     -------

	 set rebind_b  "unbind b"
	 set rebind_x  "unbind x"				//////////////////////////////////
	 set rebind_v  "unbind v"				//			IMPORTANT!!!		//
	 set rebind_f9 "bind f9 vstr hud1"		//								//
	 set rebind_f10"bind f10 vstr hud2"		//Change these Bindings to bind	//
	 set rebind_f11"bind f11 vstr hud3"		//the keys to whatever they are	//
	 set rebind_1  "unbind 1"				//bound to in your config. if	//
	 set rebind_2  "unbind 2"				//they are not bound to anything//
	 set rebind_3  "unbind 3"				//just leave them at "unbind []"//
	 set rebind_4  "unbind 4"				//								//
	 set rebind_5  "unbind 5"				//			example:			//
	 set rebind_6  "unbind 6"				//set rebind 1 "bind 1 weapon 1"//
	 set rebind_7  "unbind 7"				//								//
	 set rebind_8  "unbind 8"				//			IMPORTANT!!!		//
	 set rebind_9  "unbind 9"				//////////////////////////////////

  //                     -------
 //                   / weapons /
//                     -------
	 
	 seta cg_weaponconfig_g		"set weapon_number 1; set cg_drawgun 0;set cg_gunx 0;  set cg_guny 0;  set cg_gunz 0; set cg_drawcrosshair 0;set cg_crosshaircolor 14; set cg_crosshairsize 24;set cg_crosshairhitstyle 1;set ammo 0"	//gauntlet
	 seta cg_weaponconfig_mg	"set weapon_number 2; set cg_drawgun 0;set cg_gunx 0;  set cg_guny 0;  set cg_gunz 0; set cg_drawcrosshair 2;set cg_crosshaircolor 5; set cg_crosshairsize 24;set cg_crosshairhitstyle 2;set ammo 3"	//MG	150	100
	 seta cg_weaponconfig_sg	"set weapon_number 3; set cg_drawgun 0;set cg_gunx 0;  set cg_guny 0;  set cg_gunz 0; set cg_drawcrosshair 2;set cg_crosshaircolor 3; set cg_crosshairsize 24;set cg_crosshairhitstyle 1;set ammo 2"	//SG	25	50
	 seta cg_weaponconfig_gl	"set weapon_number 4; set cg_drawgun 0;set cg_gunx 0;  set cg_guny 0;  set cg_gunz 0; set cg_drawcrosshair 0;set cg_crosshaircolor 5; set cg_crosshairsize 24;set cg_crosshairhitstyle 1;set ammo 1"		//GL	25	25
	 seta cg_weaponconfig_rl	"set weapon_number 5; set cg_drawgun 0;set cg_gunx 0;  set cg_guny 0;  set cg_gunz 0; set cg_drawcrosshair 7;set cg_crosshaircolor 26;set cg_crosshairsize 24;set cg_crosshairhitstyle 1;set ammo 2"		//RL	25	50
	 seta cg_weaponconfig_lg	"set weapon_number 6; set cg_drawgun 2;set cg_gunx -10;set cg_guny 2.7;set cg_gunz -8;set cg_drawcrosshair 2;set cg_crosshaircolor 25; set cg_crosshairsize 24;set cg_crosshairhitstyle 2;set ammo 4"		//LG	150	200
	 seta cg_weaponconfig_rg	"set weapon_number 7; set cg_drawgun 0;set cg_gunx 0;  set cg_guny 0;  set cg_gunz 0; set cg_drawcrosshair 2;set cg_crosshaircolor 9; set cg_crosshairsize 24;set cg_crosshairhitstyle 4;set ammo 1"	//RG	25	25
	 seta cg_weaponconfig_pg	"set weapon_number 8; set cg_drawgun 0;set cg_gunx 0;  set cg_guny 0;  set cg_gunz 0; set cg_drawcrosshair 2;set cg_crosshaircolor 25; set cg_crosshairsize 24;set cg_crosshairhitstyle 2;set ammo 3"		//PG	150	100
	 seta cg_weaponconfig_bfg	"set weapon_number 9; set cg_drawgun 0;set cg_gunx 0;  set cg_guny 0;  set cg_gunz 0; set cg_drawcrosshair 7;set cg_crosshaircolor 26; set cg_crosshairsize 24;set cg_crosshairhitstyle 1;set ammo 1"		//BFG	
	 seta cg_weaponconfig_ng	"set weapon_number 11;set cg_drawgun 0;set cg_gunx 0;  set cg_guny 0;  set cg_gunz 0; set cg_drawcrosshair 2;set cg_crosshaircolor 25; set cg_crosshairsize 24;set cg_crosshairhitstyle 1;set ammo 1"		//NG	25
	 seta cg_weaponconfig_pl	"set weapon_number 12;set cg_drawgun 0;set cg_gunx 0;  set cg_guny 0;  set cg_gunz 0; set cg_drawcrosshair 0;set cg_crosshaircolor 25; set cg_crosshairsize 24;set cg_crosshairhitstyle 1;set ammo 1"	//PL	
	 seta cg_weaponconfig_cg	"set weapon_number 13;set cg_drawgun 0;set cg_gunx 0;  set cg_guny 0;  set cg_gunz 0; set cg_drawcrosshair 2;set cg_crosshaircolor 26; set cg_crosshairsize 24;set cg_crosshairhitstyle 2;set ammo 1"		//CG	

//note you can of course change these to your liking, but for the custom crosshairs to properly work you need to keep at least all crosshair related settings, also the weapon_number and the ammo cvars are essential for the HUD and should not be removed
	 
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
//MODIFY AT YOUR OWN RISK! IF YOU DONT KNOW WHAT YOU ARE DOING, DONT CHANGE ANYTHING BELOW THIS LINE!	(add it to your cfg though)				//
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////


  //                     -------
 //                   / Scripts /
//                     -------

	 alias +zoom_crosshair "set zoom_cross 1"
	 alias -zoom_crosshair "set zoom_cross 0"
	 
	 alias +altbind "vstr altbind_v;vstr altbind_b;vstr altbind_f9;vstr altbind_f10;vstr altbind_f11"
	 alias -altbind "vstr rebind_v;vstr rebind_b;vstr rebind_f9;vstr rebind_f10;vstr rebind_f11"
	 
//-----------------------------------VOTING----------------------------------------------------------------//	 
	 
	 set duelbinds	"set binds 1;exec Duel_binds.cfg;set binds_toggle vstr tdmbinds"
	 set tdmbinds	"set binds 3;exec TDM_Binds.cfg;set binds_toggle vstr cabinds"
	 set cabinds	"set binds 4;exec CA_Binds.cfg;  set binds_toggle vstr ctfbinds"
	 set ctfbinds	"set binds 5;exec CTF_Binds.cfg; set binds_toggle vstr duelbinds"
	 set binds_toggle "vstr duelbinds"
	 
		
     set votereset "set voting 0;vstr rebind_x;vstr rebind_1;vstr rebind_2;vstr rebind_3;vstr rebind_4;vstr rebind_5;vstr rebind_6;vstr rebind_7;vstr rebind_8;vstr rebind_9;set voting_toggle vstr voting_on"
	 vstr votereset

	 
	 set vote_ruleset_1	"callvote ruleset ql;vstr votereset"
	 set vote_ruleset_2	"callvote ruleset pql;vstr votereset"
	 
	 set vote_teamsize_1	"callvote teamsize 1;vstr votereset"
	 set vote_teamsize_2	"callvote teamsize 2;vstr votereset"
	 set vote_teamsize_3	"callvote teamsize 3;vstr votereset"
	 set vote_teamsize_4	"callvote teamsize 4;vstr votereset"
	 set vote_teamsize_5	"callvote teamsize 5;vstr votereset"
	 set vote_teamsize_6	"callvote teamsize 6;vstr votereset"
	 set vote_teamsize_7	"callvote teamsize 7;vstr votereset"
	 set vote_teamsize_8	"callvote teamsize 8;vstr votereset"

//------------------------------------------------------------------------------------------------------------//


//----------------------------------HUD APPEARANCE------------------------------------------------------------//
	 
	 set timer1 "set timer 1; set timertoggle vstr timer2"												//toggle for the Timer
	 set timer2 "set timer 2; set timertoggle vstr timer1"												//
	 set timertoggle "vstr timer1"		
	 
	 
	 set baron "cg_weaponbar 1; set barswitch vstr baroff; echo Weaponbar ON"							//toggle for the weaponbar
	 set baroff "cg_weaponbar 0; set barswitch vstr baron; echo Weaponbar OFF"							//
	 set barswitch "vstr baroff"																		//
	 
	 set hud1 "vstr hud1_toggle"																		//duel hud toggle
	 set hud2 "vstr hud2_toggle"																		//ca hud toggle
	 set hud3 "vstr hud3_toggle"																		//insta hud toggle
	 
	 set hud1_noxhair "vstr hud1_toggle_noxhair"
	 set hud2_noxhair "vstr hud2_toggle_noxhair"
	 set hud3_noxhair "vstr hud3_toggle_noxhair"
	 	   
	 set hud1_1_noxhair "seta cg_hudfiles ui/holmesHUD/holmes_duel_small_noxhair.cfg;loadhud;echo DUEL HUD 1...Loaded;set hud1_toggle_noxhair vstr hud1_2_noxhair"
	 set hud1_2_noxhair "seta cg_hudfiles ui/holmesHUD/holmes_duel_medium_noxhair.cfg;loadhud;echo DUEL HUD 2...Loaded;set hud1_toggle_noxhair vstr hud1_3_noxhair"
	 set hud1_3_noxhair "seta cg_hudfiles ui/holmesHUD/holmes_duel_large_noxhair.cfg;loadhud;echo DUEL HUD 3...Loaded;set hud1_toggle_noxhair vstr hud1_4_noxhair"
	 set hud1_4_noxhair "seta cg_hudfiles ui/holmesHUD/holmes_duel_supersize_noxhair.cfg;loadhud;echo DUEL HUD 4...Loaded;set hud1_toggle_noxhair vstr hud1_1_noxhair"
	 set hud1_toggle_noxhair "vstr hud1_1_noxhair"
	 
	 set hud1_1 "seta cg_hudfiles ui/holmesHUD/holmes_duel_small.cfg;loadhud;echo DUEL HUD 1...Loaded;set hud1_toggle vstr hud1_2"
	 set hud1_2 "seta cg_hudfiles ui/holmesHUD/holmes_duel_medium.cfg;loadhud;echo DUEL HUD 2...Loaded;set hud1_toggle vstr hud1_3"
	 set hud1_3 "seta cg_hudfiles ui/holmesHUD/holmes_duel_large.cfg;loadhud;echo DUEL HUD 3...Loaded;set hud1_toggle vstr hud1_4"
	 set hud1_4 "seta cg_hudfiles ui/holmesHUD/holmes_duel_supersize.cfg;loadhud;echo DUEL HUD 4...Loaded;set hud1_toggle vstr hud1_1"
	 set hud1_toggle "vstr hud1_1"
	 
	 set hud2_1_noxhair "seta cg_hudfiles ui/holmesHUD/holmes_ca_noxhair.cfg;vstr load2_1;loadhud;echo CLAN ARENA HUD ...Loaded"
	 set hud2_toggle_noxhair "vstr hud2_1_noxhair"
	 
	 set hud2_1 "seta cg_hudfiles ui/holmesHUD/holmes_ca.cfg;vstr load2_1;loadhud;echo CLAN ARENA HUD ...Loaded"
	 set hud2_toggle "vstr hud2_1"
	 
	 set hud3_1_noxhair "seta cg_hudfiles ui/holmesHUD/holmes_insta_noxhair.cfg;vstr load 3_1;loadhud;echo INSTAGIB HUD ...Loaded"
	 set hud3_toggle_noxhair "vstr hud3_1_noxhair"
	  
	 set hud3_1 "seta cg_hudfiles ui/holmesHUD/holmes_insta.cfg;vstr load 3_1;loadhud;echo INSTAGIB HUD ...Loaded"
	 set hud3_toggle "vstr hud3_1"
	 
//------------------------------------------------------------------------------------------------------------------//	 
